<?php

namespace App\Http\Controllers\admin;

use App\Dao\OrdersDao;
use App\Services\Code;

class OrdersController extends BaseController
{
    public function orders(){
        if(getIsHasPage()){
            return  Code::message('',200,OrdersDao::pageOrders(request()->all()));
        }
        $countOrder = OrdersDao::count();
        return view('admin.orders.orders',[
            'countOrder'=>$countOrder
        ]);
    }
}
